
CREATE SEQUENCE SEQ_SYS_USER_ID START WITH 1;


-- 菜单SQL
INSERT INTO sys_menu (menu_id,parent_id, name, url, perms, type, icon, order_num)
    VALUES (SEQ_MENU_ID.nextval,'1', '用户', 'sys/sysUser.html', NULL, '1', 'fa fa-file-code-o', '6');

-- 按钮父菜单ID
-- 需要替换 @parentId 
-- select SEQ_MENU_ID.currval from dual; 

-- 菜单对应按钮SQL
INSERT INTO sys_menu (menu_id,parent_id, name, url, perms, type, icon, order_num)
    SELECT SEQ_MENU_ID.nextval, @parentId, '查看', null, 'sysuser:list,sysuser:info', '2', null, '1' from dual; 
INSERT INTO sys_menu (menu_id,parent_id, name, url, perms, type, icon, order_num)
    SELECT SEQ_MENU_ID.nextval, @parentId, '新增', null, 'sysuser:save', '2', null, '2' from dual; 
INSERT INTO sys_menu (menu_id,parent_id, name, url, perms, type, icon, order_num)
    SELECT SEQ_MENU_ID.nextval, @parentId, '修改', null, 'sysuser:update', '2', null, '3' from dual; 
INSERT INTO sys_menu (menu_id,parent_id, name, url, perms, type, icon, order_num)
    SELECT SEQ_MENU_ID.nextval, @parentId, '删除', null, 'sysuser:delete', '2', null, '4' from dual; 

commit;
